<template>
	<view class="menu">
		<u-popup :show="show" @close="show = false" mode="right">
			<!--#ifdef MP-WEIXIN-->
			<view class="w-360 ph-40" :style="{ paddingTop: statusBarHeight+10 + 'px' }">
				<view class="pt-46 border">
					<view class="f ai-c mb-40" @click="toMyCollect">
						<image src="http://cwht.ricecs.cn/app/mine/wdsc.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的收藏</view>
					</view>
					<view class="f ai-c mb-40" @click="toOrderList">
						<image src="http://cwht.ricecs.cn/app/mine/wddd.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的订单</view>
					</view>
					<view class="f ai-c mb-40" @click="toDraft">
						<image src="http://cwht.ricecs.cn/app/mine/cgx.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">草稿箱</view>
					</view>
				</view>
				<view class="pt-46 border">
					<view class="f ai-c mb-40" @click="toAboutUs">
						<image src="http://cwht.ricecs.cn/app/mine/gywm.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">关于我们</view>
					</view>
					<view class="f ai-c mb-40" @click="toScore">
						<image src="http://cwht.ricecs.cn/app/mine/wdjf.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的积分</view>
					</view>
					<view class="f ai-c mb-40" @click="toCoupon">
						<image src="http://cwht.ricecs.cn/app/mine/wdyhj.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的优惠券</view>
					</view>
				</view>
				<view class="pt-46 border">
					<!-- <view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/smrz.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">实名认证</view>
					</view> -->
					<view class="f ai-c mb-40" @click="toShangJia">
						<image src="http://cwht.ricecs.cn/app/mine/sjrz.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">成为商家</view>
					</view>
					<view class="f ai-c mb-40" @click="toCongYi">
						<image src="http://cwht.ricecs.cn/app/mine/cwcy.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">成为宠医</view>
					</view>
				</view>
				<view class="pt-46 border">
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/appfx.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">APP分享</view>
					</view>
				</view>
				<view class="f ai-c jc-s-b mt-64">
					<view class="f ai-c fd-c ph-12" @click="tosetUp">
						<view class="w-96 h-96 b-96 bg f ai-c jc-c">
							<image src="http://cwht.ricecs.cn/app/mine/set.png" class="w-48 h-48"></image>
						</view>
						<view class="fs-24 text-color4 mt-16">设置</view>
					</view>
					<view class="f ai-c fd-c" @click="toQuestion">
						<view class="w-96 h-96 b-96 bg f ai-c jc-c">
							<image src="http://cwht.ricecs.cn/app/mine/cjwt.png" class="w-48 h-48"></image>
						</view>
						<view class="fs-24 text-color4 mt-16">常见问题</view>
					</view>
				</view>
			</view>
			<!--#endif-->
			<!--#ifdef APP-PLUS-->
			<view class="w-360 ph-40">
				<view class="pt-46 border">
					<view class="f ai-c mb-40" @click="toMyCollect">
						<image src="http://cwht.ricecs.cn/app/mine/wdsc.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的收藏</view>
					</view>
					<view class="f ai-c mb-40" @click="toOrderList">
						<image src="http://cwht.ricecs.cn/app/mine/wddd.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的订单</view>
					</view>
					<view class="f ai-c mb-40" @click="toDraft">
						<image src="http://cwht.ricecs.cn/app/mine/cgx.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">草稿箱</view>
					</view>
				</view>
				<view class="pt-46 border">
					<view class="f ai-c mb-40" @click="toAboutUs">
						<image src="http://cwht.ricecs.cn/app/mine/gywm.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">关于我们</view>
					</view>
					<view class="f ai-c mb-40" @click="toScore">
						<image src="http://cwht.ricecs.cn/app/mine/wdjf.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的积分</view>
					</view>
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/wdyhj.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">我的优惠券</view>
					</view>
				</view>
				<view class="pt-46 border">
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/smrz.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">实名认证</view>
					</view>
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/sjrz.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">成为商家</view>
					</view>
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/cwcy.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">成为宠医</view>
					</view>
				</view>
				<view class="pt-46 border">
					<view class="f ai-c mb-40">
						<image src="http://cwht.ricecs.cn/app/mine/appfx.png" class="w-32 h-32 mr-20"></image>
						<view class="fs-32 text-color4">APP分享</view>
					</view>
				</view>
				<view class="f ai-c jc-s-b mt-64">
					<view class="f ai-c fd-c ph-12" @click="tosetUp">
						<view class="w-96 h-96 b-96 bg f ai-c jc-c">
							<image src="http://cwht.ricecs.cn/app/mine/set.png" class="w-48 h-48"></image>
						</view>
						<view class="fs-24 text-color4 mt-16">设置</view>
					</view>
					<view class="f ai-c fd-c" @click="toQuestion">
						<view class="w-96 h-96 b-96 bg f ai-c jc-c">
							<image src="http://cwht.ricecs.cn/app/mine/cjwt.png" class="w-48 h-48"></image>
						</view>
						<view class="fs-24 text-color4 mt-16">常见问题</view>
					</view>
				</view>
			</view>
			<!--#endif-->

		</u-popup>
	</view>
</template>
<script setup lang="ts">
	import { ref } from 'vue';
	const show = ref(false);
	const getShow = () => {
		show.value = true;
	};
	//商家
	function toShangJia() {
	    uni.navigateTo({
	          url: '/pages_mine/settled/index',
	    });
	}
	//商家
	function toCongYi() {
	    uni.navigateTo({
	        url: '/pages_mine/doctorSettled/index',
	    });
	}
	//订单记录
	function toOrderList() {
	    uni.navigateTo({
	        url: '/pages_mine/order',
	    });
	}
	//积分记录
	function toScore() {
	    uni.navigateTo({
	        url: '/pages_mine/integral',
	    });
	}
	//常见问题
	function toQuestion() {
		uni.navigateTo({
			url: '/pages_mine/question',
		});
	}
	//设置
	function tosetUp() {
		uni.navigateTo({
			url: '/pages_mine/setUp',
		});
	}
	//关于我们
	function toAboutUs() {
		uni.navigateTo({
			url: '/pages_mine/aboutUs',
		});
	}
	//收藏
	function toMyCollect() {
		uni.navigateTo({
			url: '/pages_mine/myCollect/index',
		});
	}
	//草稿
	function toDraft() {
		uni.navigateTo({
			url: '/pages_mine/draft',
		});
	}
	//优惠卷
	function toCoupon() {
	    uni.navigateTo({
	        url: '/pages_index/couponCenter',
	    });
	}
	//头部
	const systemInfo = uni.getSystemInfoSync();
	const statusBarHeight = systemInfo.statusBarHeight;
	defineExpose({
		getShow,
	});
</script>
<style lang="scss" scoped>
	.menu {
		.border {
			border-bottom: 1px solid #f5f5f5;
		}

		.bg {
			background: #f5f5f5;
		}
	}
</style>